package com.sealer.pattern.behavioral.visitor;

/**
 * Created by sealer on 17/04/09.
 */
public class CarElementPrintVisitor implements CarElementVisitor {
    @Override
    public void visit(final Body body) {
        System.out.println("Visiting my body");
    }

    @Override
    public void visit(final Engine engine) {
        System.out.println("Visiting my engine");
    }

    @Override
    public void visit(final Wheel wheel) {
        System.out.println("Visiting my " + wheel.getName() + " wheel");
    }

    @Override
    public void visit(final Car car) {
        System.out.println("Visiting my car");
    }
}
